package com.gitee.zhanyao.api.security.model;

import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import org.springframework.security.core.GrantedAuthority;
import org.springframework.security.core.userdetails.User;

import java.util.Collection;

/**
 * @author zhanyao
 */
@Getter
@Setter
public class OAuth2User extends User {

    private String email;

    public OAuth2User(String username, String password, Collection<? extends GrantedAuthority> authorities,String email) {
        super(username, password, authorities);
        this.email = email;
    }

}
